//
//  SoundBean.swift
//  imprint
//
//  Created by 小柠檬🍋 on 2025/2/5.
//

import Foundation

//语音
class SoundBean : Codable, Identifiable {
    var url: String? = nil
    var duration: TimeInterval? = nil
    var fileId: String? = nil
    var urlTime: TimeInterval = 0//url过期时间
    
    func getDurationStr() -> String {
        if let unwrappedDuration = duration {
            let intDuration2 = Int(unwrappedDuration)
            return "\(intDuration2)"
        } else {
            return "1"
        }
    }
}
